const router = require('express').Router()

const { createGoods, getGoodsList, getTotal, searchGoods } = require('../controllers/goods')

// 爬取商品
router.get('/spider/:id', createGoods)
// 商品列表
router.get('/list/:current', getGoodsList )
// 获取总页数
router.get('/total', getTotal)
// 搜索商品
router.post('/list', searchGoods)

module.exports = router
